home *** CD-ROM | disk | FTP | other *** search
/ ASL 120: Business 2 / ASL 120: Business 2.iso / aslvol20 / appl17 / install.bat < prev    next >
DOS Batch File  |  1992-11-28  |  2KB  |  93 lines

  1. @echo off
  2. cls
  3. echo/
  4. echo                Easy Agent for MS-DOS Install.bat
  5. echo               -----------------------------------
  6. echo/
  7. echo    Use this program to install Easy Agent 1.45 on your system.
  8. echo/
  9. echo    INSTALL.BAT requires approximately 600k bytes of free disk space.
  10. echo    Make sure the correct amount of disk space is available before
  11. echo    attempting to install.  CTRL+C will exit the batch file.
  12. echo/
  13.  
  14. rem Check arguments
  15. if not "%1" == "" goto be_sure
  16. if not "%2" == "" goto be_sure
  17. if not "%3" == "" goto be_sure
  18.  
  19. rem Show usage summary
  20. echo    Usage: INSTALL disk-count source-drive destination-drive
  21. echo/
  22. echo    Where:
  23. echo    disk-count        is the number of floppy disks, 1
  24. echo    source-drive      is a: or b:
  25. echo    destination-drive is c:, d:, etc
  26. echo    Example:          INSTALL 1 a: c:
  27. echo    "Type-in INSTALL 1 a: c: to install Easy Agent onto C:> drive"
  28. echo    "Type-in INSTALL 1 a: b: to install Easy Agent onto Floppy Drive"
  29. echo    "Type-in INSTALL 1 a: d: to install Easy Agent onto D:> drive"
  30. echo    "If your Floppy disk is B:>, Type-in INSTALL 1 b: c:"
  31. echo/
  32. goto end
  33. :be_sure
  34. echo/
  35. echo    This program performs only minimal error checking; be sure your
  36. echo    parameters are correct.
  37. echo/
  38. echo    Number of disks:  %1
  39. echo    Source:           %2
  40. echo    Destination:      %3\realty
  41. echo/
  42. pause
  43.  
  44. rem Make destination directory
  45. echo Creating %3\realty
  46. if not exist %3\realty\*.* mkdir %3\realty
  47. echo test >%3\realty\test.txt
  48. if exist %3\realty\test.txt goto copy
  49.     echo %0: error unable to create %3\realty
  50.     goto end
  51. :copy
  52. del %3\realty\test.txt
  53.  
  54. echo/
  55. echo    Insert program disk
  56. pause
  57.  
  58. rem Move to distribution disk
  59. if exist %2\easy-a14.exe goto disk1
  60.     echo %0: error %2\easy-a14.exe not found
  61.     goto end
  62. :disk1
  63.  
  64. echo    Copying files from distribution disk
  65. copy %2\ %3\realty
  66.  
  67. if %1 == 1 goto decompress
  68.  
  69. :decompress
  70.  
  71. rem Move to destination
  72. %3
  73. chdir %3\realty
  74. if exist easy-a14.exe goto chdir_ok
  75.     echo %0: error moving to %3\realty (easy-a14.exe not found)
  76.     goto end
  77. :chdir_ok
  78.  
  79. rem Decompress files
  80. if exist easy-a14.exe  easy-a14.exe
  81. if exist lagent.exe  lagent.exe
  82.  
  83. :exist_eagent
  84.  
  85. rem Done
  86. cls
  87. echo/
  88. echo    Easy Agent 1.45 for MS-DOS, installation complete.
  89. echo    Type-in AGENT and press enter to start the program.
  90. echo
  91. :end
  92. echo/ 
  93.